package com.example.demo.exception;


import lombok.Getter;
import lombok.Setter;

/**
 * @author wumin
 * @version 1.0
 * @Description: 业务异常
 * @date 2021/4/7 15:18
 */
@Setter
@Getter
public class BusinessException extends RuntimeException {

    private int code;

    public BusinessException() {
        super();
    }

    public BusinessException(String msg) {
        super(msg);
        this.code = 500;
    }

    public BusinessException(int code, String msg) {
        super(msg);
        this.code = code;
    }
}
